Dynomotion

Group: DynoMotion Message: 889 From: ca_gray751 Date: 1/31/2011
Subject: Pass a variable from Mach3 to the homing routine
Tom,

Is is possible to pass a number from a mach3 user dro to the homing routine?

Every now and then a table operator has to check for table squareness and needs a way to make small adjustments so the slave motor will move off the home prox slightly more or less than the master motor.


Thanks,
Allen
Group: DynoMotion Message: 895 From: ca_gray751 Date: 2/2/2011
Subject: Re: Pass a variable from Mach3 to the homing routine
Tom,

Any thoughts on this? I know we talked about this once before via email. I went through some past emails and found some dated 12/17 where you had an idea on how to handle this situation.

Thanks,
Allen


--- In DynoMotion@yahoogroups.com, "ca_gray751" <agray@...> wrote:
>
> Tom,
>
> Is is possible to pass a number from a mach3 user dro to the homing routine?
>
> Every now and then a table operator has to check for table squareness and needs a way to make small adjustments so the slave motor will move off the home prox slightly more or less than the master motor.
>
>
> Thanks,
> Allen
>
Group: DynoMotion Message: 896 From: Tom Kerekes Date: 2/2/2011
Subject: Re: Pass a variable from Mach3 to the homing routine
Hi Allen,
 
I was thinking to create a range of notification messages that would pass a corresponding Mach3 DRO into a KFlop persist.UserData variable as a 32 bit floating point number.  So for example if the assigned notification message range was 19000 to 19099.  To transfer Mach3 DRO #7 to KFlop UserData[7] you would need to execute NotifyPlugins(19007).
 
Regards
TK
 
Group: DynoMotion Message: 897 From: ca_gray751 Date: 2/2/2011
Subject: Re: Pass a variable from Mach3 to the homing routine
Good thought! Keep in mind that valid user DRO range in Mach3 is 1001-1255.

When do you think something like that could be incorporated? :)





--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Hi Allen,
>
> I was thinking to create a range of notification messages that would pass a
> corresponding Mach3 DRO into a KFlop persist.UserData variable as a 32 bit
> floating point number.  So for example if the assigned notification message
> range was 19000 to 19099.  To transfer Mach3 DRO #7 to KFlop UserData[7] you
> would need to execute NotifyPlugins(19007).
>
> Regards
> TK
>
>
> ________________________________
> From: ca_gray751 <agray@...>
> To: DynoMotion@yahoogroups.com
> Sent: Wed, February 2, 2011 9:46:14 AM
> Subject: [DynoMotion] Re: Pass a variable from Mach3 to the homing routine
>
>  
> Tom,
>
> Any thoughts on this? I know we talked about this once before via email. I went
> through some past emails and found some dated 12/17 where you had an idea on how
> to handle this situation.
>
> Thanks,
> Allen
>
> --- In DynoMotion@yahoogroups.com, "ca_gray751" <agray@> wrote:
> >
> > Tom,
> >
> > Is is possible to pass a number from a mach3 user dro to the homing routine?
> >
> > Every now and then a table operator has to check for table squareness and needs
> >a way to make small adjustments so the slave motor will move off the home prox
> >slightly more or less than the master motor.
> >
> >
> > Thanks,
> > Allen
> >
>
Group: DynoMotion Message: 902 From: Tom Kerekes Date: 2/3/2011
Subject: Re: Pass a variable from Mach3 to the homing routine
Allen,
 
Here is a new plugin that should work with V4.23.  Copy to your Mach3/Plugins directory.
 
It should report as V4.23d
 
 
Below is a description and example.
 
Let me know if it has any problems.
 
Thanks
TK
 

 
Mechanism for transfering values back and forth between Mach3 and KFLOP
 
 
Mach3 User DROs 1 to 50 map to KFlop UserData 0 to 99 (2 words each double)
 
 
To Read from KFLOP to Mach3 use NotifyPlugins codes 18001 to 18050
To Write from Mach3 to KFLOP use NotifyPlugins codes 19001 to 19050
 
 
Example MACH3 SIDE
 
SetOEMDRO(1007,123.456)  'Put a value in a Mach DRO
NotifyPlugins(19007)     'Send it to KFLOP
Sleep(3000)              'Wait for KFLOP to modify and copy it
NotifyPlugins(18008)     'Read the result from KFLOP
x=GetOEMDRO(1008)        'Check the value passed back

Example KFLOP SIDE
 
#include "KMotionDef.h"
#define DROIN 7
#define DROOUT 8
main()
{
    double *pin  = (double *)&persist.UserData[(DROIN -1)*2];
    double *pout = (double *)&persist.UserData[(DROOUT-1)*2];
    for(;;)
    {
        Delay_sec(2);
        *pout = *pin + 999;
        printf("DROIN %d = %f DROOUT %d = %f\n",DROIN,*pin,DROOUT,*pout);
    }
}

Group: DynoMotion Message: 903 From: ca_gray751 Date: 2/4/2011
Subject: Re: Pass a variable from Mach3 to the homing routine
Thanks Tom. I will test this when I get back in the office on Monday.

Allen



--- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@...> wrote:
>
> Allen,
>
> Here is a new plugin that should work with V4.23.  Copy to your Mach3/Plugins
> directory.
>
> It should report as V4.23d
>
> http://www.dynomotion.com/Software/Mach3DRO/Dynomotion.dll
>
> Below is a description and example.
>
> Let me know if it has any problems.
>
> Thanks
> TK
>
>
>  
> Mechanism for transfering values back and forth between Mach3 and KFLOP
>  
>  
> Mach3 User DROs 1 to 50 map to KFlop UserData 0 to 99 (2 words each double)
>  
>  
> To Read from KFLOP to Mach3 use NotifyPlugins codes 18001 to 18050
> To Write from Mach3 to KFLOP use NotifyPlugins codes 19001 to 19050
>  
>
> Example MACH3 SIDE
>
> SetOEMDRO(1007,123.456)  'Put a value in a Mach DRO
> NotifyPlugins(19007)     'Send it to KFLOP
> Sleep(3000)              'Wait for KFLOP to modify and copy it
> NotifyPlugins(18008)     'Read the result from KFLOP
> x=GetOEMDRO(1008)        'Check the value passed back
>
>
> Example KFLOP SIDE
>  
> #include "KMotionDef.h"
> #define DROIN 7
> #define DROOUT 8
> main()
> {
>     double *pin  = (double *)&persist.UserData[(DROIN -1)*2];
>     double *pout = (double *)&persist.UserData[(DROOUT-1)*2];
>     for(;;)
>     {
>         Delay_sec(2);
>         *pout = *pin + 999;
>         printf("DROIN %d = %f DROOUT %d = %f\n",DROIN,*pin,DROOUT,*pout);
>     }
> }
>
>
> ________________________________
> From: ca_gray751 <agray@...>
> To: DynoMotion@yahoogroups.com
> Sent: Wed, February 2, 2011 10:51:14 AM
> Subject: [DynoMotion] Re: Pass a variable from Mach3 to the homing routine
>
>  
> Good thought! Keep in mind that valid user DRO range in Mach3 is 1001-1255.
>
> When do you think something like that could be incorporated? :)
>
> --- In DynoMotion@yahoogroups.com, Tom Kerekes <tk@> wrote:
> >
> > Hi Allen,
> >
> > I was thinking to create a range of notification messages that would pass a
> > corresponding Mach3 DRO into a KFlop persist.UserData variable as a 32 bit
> > floating point number.  So for example if the assigned notification message
> > range was 19000 to 19099.  To transfer Mach3 DRO #7 to KFlop UserData[7] you
> > would need to execute NotifyPlugins(19007).
> >
> > Regards
> > TK
> >
> >
> > ________________________________
> > From: ca_gray751 <agray@>
> > To: DynoMotion@yahoogroups.com
> > Sent: Wed, February 2, 2011 9:46:14 AM
> > Subject: [DynoMotion] Re: Pass a variable from Mach3 to the homing routine
> >
> >  
> > Tom,
> >
> > Any thoughts on this? I know we talked about this once before via email. I went
> >
> > through some past emails and found some dated 12/17 where you had an idea on
> >how
> >
> > to handle this situation.
> >
> > Thanks,
> > Allen
> >
> > --- In DynoMotion@yahoogroups.com, "ca_gray751" <agray@> wrote:
> > >
> > > Tom,
> > >
> > > Is is possible to pass a number from a mach3 user dro to the homing routine?
> > >
> > > Every now and then a table operator has to check for table squareness and
> >needs
> >
> > >a way to make small adjustments so the slave motor will move off the home prox
> >
> > >slightly more or less than the master motor.
> > >
> > >
> > > Thanks,
> > > Allen
> > >
> >
>
Group: DynoMotion Message: 940 From: Gerry Date: 3/6/2011
Subject: Re: Pass a variable from Mach3 to the homing routine
Actually, the range goes much higher than what the Wiki says. IT was increased at some point.

Not sure of the upper limit, but I think it might be 2000. I use UserDRO's in the 1800 range in my custom screen.

Gerry



--- In DynoMotion@yahoogroups.com, "ca_gray751" <agray@...> wrote:
>
> Good thought! Keep in mind that valid user DRO range in Mach3 is 1001-1255.